<table class="table table-border table-bordered table-hover table-bg">
    <thead>
    <tr class="text-c">
        <th width="25">序号</th>
        <th>姓名</th>
        <th>工牌号</th>
        <th>部门</th>
        <th>性别</th>
        <th>联系方式</th>
        <th>状态</th>
        <th>负责区域</th>
        <th>负责小区</th>
        <th width="50">操作</th>
    </tr>
    </thead>
    <tbody>
    <tr class="text-c">
        <td>1</td>
        <td>张三</td>
        <td>G001</td>
        <td>工程部</td>
        <td>男</td>
        <td>18989568956</td>
        <td>在职</td>
        <td>重庆—渝北区</td>
        <td>东源星月、凡尔赛公馆</td>
        <td>
            <a href="javascript:void(0);" title="编辑"  onclick="admin_role_add('编辑任务人员信息','add.html','800', '420')"><i class="Hui-iconfont">&#xe60c;</i></a>
            <a href="javascript:void(0);" class="dels" roomid="{$user['roomid']}" title="删除" style="text-decoration:none"><i class="Hui-iconfont">&#xe6e2;</i></a>
        </td>
    </tr>
    </tbody>
</table>
<!--page-->
<include file="Common/page" />
<script>
    $(document).ready(function(){
        $(".dels").on('click', function(){
            var obj = $(this);
            layer.confirm('删除操作为不可逆操作，是否删除该条记录？', {
                btn: ['确定','取消'] //按钮
            }, function(){
                $.post('room.html',{roomid: obj.attr('roomid')}, function(row){
                    if(row/1){
                        layer.msg('删除房间成功', {icon: 1, time: 2000}, function(){
                            $("#room_"+ obj.attr('roomid')).remove();
                        });
                    }else{
                        layer.msg('删除房间失败',{icon:0, time:2000});
                    }
                });
            }, function(){

            });
        });
    });
</script>